W3. Orthogonal Vector Spaces
1. Theory
1.1 Vector Spaces
A vector space
1.1.1 Definition and Axioms
Vector spaces must satisfy the following axioms for all vectors
Addition Axioms:
- Commutativity:
- Associativity:
- Identity: There exists a zero vector
such that for all - Inverses: For every
, there exists such that
Scalar Multiplication Axioms:
- Associativity:
- Identity:
- Distributivity (over vectors):
- Distributivity (over scalars):
1.1.2 Common Examples of Vector Spaces
- Euclidean spaces
: Collections of ordered -tuples of real numbers with component-wise addition and scalar multiplication - Matrix spaces
: All matrices under matrix addition and scalar multiplication - Polynomial spaces
: All polynomials of degree at most with polynomial addition and scalar multiplication - Function spaces
: All continuous functions on interval with pointwise addition and scalar multiplication
1.2 Subspaces
A subspace is a subset of a vector space that is itself a vector space under the same operations. This is a key concept because subspaces inherit the structure of the larger space while potentially having lower dimension.
1.2.1 Subspace Test
Rather than checking all eight axioms, we can use a simpler criterion. A non-empty subset
- Closed under addition: For all
, we have - Closed under scalar multiplication: For all
and , we have
These two conditions automatically guarantee closure gives us the zero vector (set
1.2.2 Examples of Subspaces
Subspaces of
- The origin:
- Any line through the origin
- Any plane through the origin
- The entire space
Not Subspaces of
- A line NOT through the origin (fails the zero vector test)
- A plane NOT through the origin (fails the zero vector test)
- The first octant
(closed under addition but NOT under scalar multiplication by negative numbers)
1.2.3 Span of Vectors
The span of a set of vectors
The span of any set of vectors is always a subspace of the ambient vector space.
1.3 Column Space and Null Space
For a matrix
1.3.1 Column Space
The column space (or range) of an
The column space answers the question: “For which vectors
1.3.2 Null Space
The null space (or kernel) of an
It is a subspace of
1.3.3 Complete Solution Structure
If
where
1.4 Inner Products and Orthogonality
An inner product generalizes the dot product to abstract vector spaces, allowing us to measure angles and distances even in high-dimensional spaces.
1.4.1 Definition of Inner Product
An inner product on a vector space
- Conjugate symmetry:
(equals for real spaces) - Linearity in first argument:
- Positive-definiteness:
, with equality if and only if
1.4.2 Standard Inner Products
- In
: (dot product) - In
: - For continuous functions:
1.4.3 Orthogonality
Two vectors
Orthogonal vectors have zero angle between them (90°).
1.4.4 Orthonormal Sets
A set of vectors
The vectors are mutually orthogonal and each has unit length (magnitude 1).
1.4.5 Projection onto a Vector
The projection of vector
This formula gives the component of
1.5 The Gram-Schmidt Orthogonalization Process
The Gram-Schmidt process is an algorithm that takes a set of linearly independent vectors and produces an orthonormal basis for the same subspace. This is invaluable because orthonormal bases simplify computations and improve numerical stability.
1.5.1 Why Orthogonalization?
Orthogonal bases are superior to arbitrary bases for several reasons:
- Simplified computations: Inner products become straightforward
- Numerical stability: Reduces round-off errors in calculations
- QR decomposition: Enables efficient matrix factorizations
- Signal processing: Removes correlations in data
- Least squares: Provides efficient solutions to overdetermined systems
1.5.2 The Algorithm
Given linearly independent vectors
Step 1: First vector
Step 2: Second vector (subtract projection of
Step 3: Third vector and beyond
For
The key insight is that we subtract from each new vector all its projections onto the previously orthonormalized vectors, ensuring orthogonality.
1.6 QR Decomposition
QR decomposition is a matrix factorization that writes any matrix with linearly independent columns as a product of an orthogonal matrix and an upper triangular matrix.
1.6.1 The QR Theorem
Every
where:
is an matrix with orthonormal columns is an upper triangular matrix with positive diagonal entries
1.6.2 Construction from Gram-Schmidt
The QR decomposition emerges naturally from the Gram-Schmidt process. If
where the
1.6.3 Computing R from Q and A
Once
This works because
1.7 Numerical Stability: Modified Gram-Schmidt
The classical Gram-Schmidt process can suffer from numerical instability when vectors are nearly linearly dependent. The modified Gram-Schmidt algorithm performs the same calculations in a different order that is more resistant to round-off errors:
Instead of projecting
2. Definitions
- Vector Space: A set with operations of addition and scalar multiplication satisfying eight axioms (closure, associativity, commutativity, identities, and inverses).
- Subspace: A non-empty subset of a vector space that is closed under addition and scalar multiplication.
- Column Space (
): The set of all linear combinations of the columns of matrix ; equivalently, the set of all such that has a solution. - Null Space (
): The set of all vectors satisfying . - Span: The set of all linear combinations of a given set of vectors; always forms a subspace.
- Basis: A linearly independent set of vectors that spans a subspace.
- Orthogonal Vectors: Two vectors whose inner product is zero; they are perpendicular.
- Orthonormal Set: A set of vectors that are mutually orthogonal and each have unit length.
- Inner Product: A function that assigns a scalar to each pair of vectors, generalizing the dot product.
- Norm (Magnitude): The length of a vector, computed as
. - Projection: The component of one vector in the direction of another, computed as
. - Gram-Schmidt Process: An algorithm that converts a linearly independent set of vectors into an orthonormal set spanning the same subspace.
- QR Decomposition: A matrix factorization
where has orthonormal columns and is upper triangular.
3. Formulas
- Dot Product (Inner Product in
): - Vector Magnitude (Norm):
- Unit Vector:
(for ) - Orthogonality Condition:
if and only if - Projection of
onto : - Orthogonal Component:
is orthogonal to - Gram-Schmidt (General Step): For
: - QR Decomposition:
where and is upper triangular - Computing R from Q and A:
4. Practice
4.1. Which Pairs Are Orthogonal (Lab 3, Task 1)
Which pairs are orthogonal among the vectors
Click to see the solution
Key Concept: Two vectors are orthogonal if their dot product equals zero:
We need to compute all pairwise dot products:
- Check
: Not orthogonal. - Check
: Orthogonal. - Check
: Not orthogonal. - Check
: Orthogonal. - Check
: Not orthogonal. - Check
: Not orthogonal.
Answer: The orthogonal pairs are
4.2. Project Vector onto Line (Lab 3, Task 2)
Project the vector
where
Click to see the solution
Key Concept: The projection of
- Compute
: - Compute
: - Calculate the projection:
- Find the error vector
: - Verify
: ✓ Indeed perpendicular.
Note: Since
Answer:
4.3. Apply Gram-Schmidt (Basic Case) (Lab 3, Task 3a)
Apply the Gram-Schmidt process to:
Click to see the solution
Key Concept: The Gram-Schmidt process converts linearly independent vectors into orthonormal vectors.
- Orthogonalize the first vector:
- Orthogonalize the second vector:
- Calculate
- Calculate
- Thus:
- Calculate
- Normalize to get orthonormal vectors:
Answer: Orthogonal vectors:
Orthonormal vectors:
4.4. Find QR Decomposition of a 3×2 Matrix (Lab 3, Task 3b)
Find the QR decomposition of:
Click to see the solution
Key Concept: QR decomposition factors a matrix with linearly independent columns as
Apply Gram-Schmidt to the columns of
: ,
First orthonormal vector:
Orthogonalize second column:
Normalize second vector:
Construct
and :From the Gram-Schmidt process, we have:
, so first column of is , so second column of is
Answer:
4.5. Orthogonalize Vectors in ℝ⁴ and Find QR Decomposition (Lab 3, Task 3c)
Orthogonalize the following vectors in
Click to see the solution
Key Concept: Gram-Schmidt orthogonalization systematically removes projections to create orthogonal vectors.
- First vector:
- Second vector:
- Third vector:
- Construct
by normalizing: - Construct
from dot products:
Answer: The orthogonal vectors are
4.6. Express Gram-Schmidt Orthogonalization as QR (Lab 3, Task 4)
Express the Gram-Schmidt orthogonalization of
Given
Click to see the solution
Key Concept: QR decomposition naturally emerges from Gram-Schmidt orthogonalization. The shapes are determined by the input dimensions.
- Apply Gram-Schmidt:
- Orthogonalize second vector:
- Normalize for
: - Construct matrices:
- Matrix shapes: Given
vectors with components: is is (with orthonormal columns) is (upper triangular)
Answer:
For
4.7. Find Orthonormal Vectors from Nonorthogonal Vectors (Lab 3, Task 5)
From the nonorthogonal vectors
Click to see the solution
Key Concept: Apply Gram-Schmidt and normalize each orthogonal vector to unit length.
- First orthonormal vector:
- Second orthonormal vector:
- Third orthonormal vector:
Answer:
4.8. Project Vector onto Two Orthogonal Lines (Lab 3, Task 6)
Project the vector
Click to see the solution
Key Concept: When basis vectors are not orthogonal, projections don’t simply add. This motivates orthogonalization.
Project
onto :Project
onto :Add the projections:
Compare with original vector:
The sum of projections does not equal
because and are not orthogonal. Check: .
Answer:
4.9. Identify Which Subsets Are Subspaces (Lab 3, Task 7)
Which of the following subsets of
- The plane of vectors
with first component . - The plane of vectors
with . - The vectors
with (the union of two subspaces: the plane and the plane ). - All combinations of two given vectors
and . - The plane of vectors
that satisfy .
Click to see the solution
Key Concept: A subset is a subspace if it contains the zero vector and is closed under addition and scalar multiplication.
(a) Vectors with
(b) Vectors with
(c) Union of planes
(d) All combinations of
(e) Vectors satisfying
Answer: Subspaces are (a), (d), and (e). Not subspaces are (b) and (c).
4.10. True or False for Matrix Subspaces (Lab 3, Task 8)
For
- The skew-symmetric matrices in
(with ) form a subspace. - The unsymmetric matrices in
(with ) form a subspace. - The matrices that have
in their nullspace form a subspace.
Click to see the solution
Key Concept: Check if subsets contain the zero matrix and are closed under matrix addition and scalar multiplication.
(a) Skew-symmetric matrices (
(b) Unsymmetric matrices (
(c) Matrices with
Answer: (a) TRUE, (b) FALSE, (c) TRUE
4.11. Show Vector in Subspace Spanned by Vectors (Assignment 3, Task 1)
Show that
Click to see the solution
Key Concept: To show
- Set up the linear system:
- This gives us the augmented matrix:
- Row reduce to find if a solution exists: After row reduction (detailed steps omitted for brevity), we can verify the system is consistent.
- Check by finding coefficients (one particular solution): After row reduction, a solution exists. One particular solution is
(confirmed by consistent RREF), confirming is in the span.
Answer:
4.12. Determine if Vector is in Column Space (Assignment 3, Task 2)
Determine if
Click to see the solution
Key Concept:
Set up the augmented matrix
:Row reduce to echelon form:
, ,
Continue reduction: After complete row reduction, check if there is a row of the form
with .If no such row exists, the system is consistent and
. If such a row exists, the system is inconsistent and .Result: Based on the reduced form, determine consistency.
Answer: Check row-reduced form: if consistent, then
4.13. Find for Null and Column Spaces (Assignment 3, Task 3)
For the matrices in Exercises 17–20, (a) find
Matrix 17:
Matrix 18:
Matrix 19:
Matrix 20:
Click to see the solution
Key Concept: For an
is a subspace of (based on number of columns) is a subspace of (based on number of rows)
Matrix 17 (
is a subspace of (2 columns)
is a subspace of (4 rows)
Matrix 18 (
is a subspace of (3 columns)
is a subspace of (4 rows)
Matrix 19 (
is a subspace of (5 columns)
is a subspace of (2 rows)
Matrix 20 (
is a subspace of (5 columns)
is a subspace of (1 row)
Answer:
- Matrix 17: (a)
, (b) - Matrix 18: (a)
, (b) - Matrix 19: (a)
, (b) - Matrix 20: (a)
, (b)
4.14. True or False: Null Space and Column Space (Assignment 3, Task 4)
For an
- The null space of
is the solution set of the equation . - The null space of an
matrix is in . - The column space of
is the range of the mapping . - If the equation
is consistent, then is . - The kernel of a linear transformation is a vector space.
- Col
is the set of all vectors that can be written as for some .
Click to see the solution
Key Concept: Understand the definitions of null space, column space, and their properties.
(a) TRUE By definition,
(b) FALSE The null space is in
(c) TRUE The range (or image) of the mapping
(d) FALSE If
(e) TRUE The kernel of a linear transformation
(f) TRUE This is the definition of column space:
Answer: (a) TRUE, (b) FALSE, (c) TRUE, (d) FALSE, (e) TRUE, (f) TRUE
4.15. True or False: Subspaces and Dimension (Assignment 3, Task 5)
For an
- A null space is a vector space.
- The column space of an
matrix is in . - Col
is the set of all solutions of . is the kernel of the mapping .- The range of a linear transformation is a vector space.
- The set of all solutions of a homogeneous linear differential equation is the kernel of a linear transformation.
Click to see the solution
Key Concept: Apply subspace criteria and definitions of fundamental matrix spaces.
(a) TRUE A null space
(b) TRUE The column space consists of all linear combinations of the
(c) FALSE The column space is the set of all vectors
(d) TRUE By definition, the kernel of
(e) TRUE The range of a linear transformation
(f) TRUE Consider a homogeneous linear differential equation like
Answer: (a) TRUE, (b) TRUE, (c) FALSE, (d) TRUE, (e) TRUE, (f) TRUE
4.16. True or False: Column Space Properties (Tutorial 3, Task 1)
True or false (with a counterexample if false)?
- The vectors
that are not in the column space form a subspace. - If
contains only the zero vector, then is the zero matrix. - The column space of
equals the column space of . - The column space of
equals the column space of .
Click to see the solution
Key Concept: Understand when sets are closed under operations and form subspaces.
(a) FALSE Counterexample: Let
More generally: If
(b) TRUE If
(c) TRUE
Since scalar multiplication by 2 is invertible (we can divide by 2), we have:
More rigorously:
(d) FALSE Counterexample: Let
These are not equal, so the statement is false.
Answer: (a) FALSE, (b) TRUE, (c) TRUE, (d) FALSE
4.17. Examples of Matrices with Varying Solution Counts (Tutorial 3, Task 2)
Give examples of matrices
- 0 or 1, depending on
. , regardless of .- 0 or
, depending on . - 1, regardless of
.
Click to see the solution
Key Concept: The number of solutions depends on the rank and dimensions of the matrix.
(a) 0 or 1 depending on
For
- If
, then the system has exactly 1 solution: - If
, there is no solution (inconsistent)
(b)
However, if we allow underdetermined systems: Example:
For any
(c) 0 or
For
- If
(consistent with the dependence of rows), there are infinitely many solutions - If
, there is no solution
(d) 1 solution regardless of
For any
More generally, any invertible
Answer: (a)
(any invertible matrix)
4.18. Find RREF and Special Solutions for Parameter-Dependent Matrix (Tutorial 3, Task 3)
For every
Click to see the solution
Key Concept: Row reduction and special solutions depend on parameter values.
First Matrix:
Row reduce:
Case 1:
Swap rows 2 and 3, then divide row 2 by
:Free variables:
Special solution for
:Special solution for
:Case 2:
Free variables:
Special solutions:
, ,
Second Matrix:
Case 1:
andInvertible diagonal matrix:
Special solution: None (only the trivial solution
)Case 2:
Free variable:
Special solution:
Case 3:
Free variable:
Special solution:
Answer: Results depend on parameter
4.19. Find Solutions to Ax = 0 and Ax = b from Given Solution (Tutorial 3, Task 4)
- If
has two solutions and , find two solutions to . - Then find another solution to
.
Click to see the solution
Key Concept: The difference of two solutions to
(a) Find two solutions to
From
So
Similarly,
Since both
Alternative answer: More generally, any scalar multiple
(b) Find another solution to
The complete solution to
where
We can use
Verify:
Answer: (a) Two solutions to
- Another solution to
is: (or for any scalar )
4.20. Conditions for Solvability and Solution Structure (Tutorial 3, Task 5)
What conditions on
Click to see the solution
Key Concept: A system is solvable if and only if
First System:
Row reduce the augmented matrix:
After row operations:
Further reducing:
Solvability conditions: For consistency:
Solution (when solvable):
,
Second System:
Row reduce the augmented matrix:
After row reduction (details omitted):
Solvability conditions:
Solution (when solvable): With free variable
:
Answer: First system is solvable iff
Second system is solvable iff
4.21. Write Complete Solutions as (Tutorial 3, Task 6)
Write the complete solutions
Click to see the solution
Key Concept: Complete solution = particular solution + null space solution:
First System:
Row reduce the augmented matrix:
Find particular solution: From row 2:
From row 1:Choose
:Particular solution:
Find null space (special solution): The null space comes from
with free variable .Set
: . Special solution:Complete solution:
Second System:
Row reduce the augmented matrix:
Check consistency: Row 2 says
, which is impossible.This system has no solution.
Answer: First system:
Second system: No solution (inconsistent)
4.22. Find Unsolvable System with Infinite Solutions in Null Space (Tutorial 3, Task 7)
Write a
Click to see the solution
Key Concept: For a system to be unsolvable yet have a non-trivial null space, we need a rank-deficient matrix with
Construct the system: Let
(rank 1, second row is 2 times the first)The column space is
(the line through )The null space is
(infinite solutions to )Choose
not in Col : Let (not a multiple of )Check:
gives:From the first equation:
Substitute into the second: ✗No solution, but the null space has infinite vectors.
Which
’s allow a solution? Only for any scalar .These are vectors in the column space of
.
Answer: Example system:
This system has no solution, but
For the system to be solvable,
4.23. Find Matrix from Complete Solution (Tutorial 3, Task 8)
Find the matrix
Click to see the solution
Key Concept: The complete solution tells us the particular solution and the null space. From these, we can reconstruct
Interpret the solution:
- Particular solution:
- Null space direction:
- Particular solution:
Find constraints on
from the null space: If is in , then:If
, then:So
and :Use the particular solution:
:So
and :Verify: Complete solution to
:Particular solution:
✓Null space:
, with free , so ✓
Answer:
4.24. Find Echelon Form and Complete Solution (Tutorial 3, Task 9)
Find the echelon form
Click to see the solution
Key Concept: Echelon form reveals pivots, free variables, and solvability constraints.
Row reduce to echelon form:
Note: Column 1 has no pivot (skip it).
:Echelon form
:Solvability condition: For consistency:
, i.e.,Pivot and free variables:
- Pivot columns: column 2 (variable
) - Free variables:
- Pivot columns: column 2 (variable
Particular solution (set free variables to 0):
From row 1:Special solutions (null space): From row 1:
- Set
: , giving - Set
: , giving - Set
: , giving
- Set
Complete solution:
Answer: Echelon form:
Solvability condition:
Free variables:
Complete solution:
4.25. Find Invertible Submatrix from Rank (Tutorial 3, Task 10)
If
Click to see the solution
Key Concept: The submatrix formed by the intersection of pivot rows and pivot columns is invertible.
Matrix 1:
Row reduce:
Identify pivots:
- Row 1, Column 1: pivot
- Row 2, Column 3: pivot Rank = 2
Submatrix
: Take rows 1 and 2, columns 1 and 3:Verify:
✓
Matrix 2:
Row reduce:
Identify pivots:
- Row 1, Column 1: pivot Rank = 1
Submatrix
: Take row 1, column 1:Verify:
✓
Matrix 3:
Already in echelon form:
- Row 1, Column 2: pivot
- Row 3, Column 3: pivot Rank = 2
Submatrix
: Take rows 1 and 3, columns 2 and 3:Verify:
✓
Answer:
- Matrix 1:
(rank 2) - Matrix 2:
(rank 1) - Matrix 3:
(rank 2)